//
//  OwnerCell.m
//  SpiritWalk
//
//  Created by dllo on 16/3/18.
//  Copyright © 2016年 王鑫. All rights reserved.
//

#import "OwnerCell.h"

@implementation OwnerCell

-(id)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier{
    
    self=[super initWithStyle:style reuseIdentifier:reuseIdentifier];
    if (self) {
        [self createCell];
    }
    return self;
}

-(void)createCell{
    UICollectionViewFlowLayout *flowLayout=[[UICollectionViewFlowLayout alloc] init];
    self.ownerCollectionView=[[UICollectionView alloc] initWithFrame:CGRectMake(0, 0, WIDTH, HEIGHT-353) collectionViewLayout:flowLayout];
    flowLayout.itemSize=CGSizeMake(WIDTH, HEIGHT-353);
    flowLayout.minimumInteritemSpacing=0;
    flowLayout.minimumLineSpacing=0;
    flowLayout.scrollDirection=UICollectionViewScrollDirectionHorizontal;
    [self.contentView addSubview:self.ownerCollectionView];
    self.ownerCollectionView.pagingEnabled=YES;
    
}
-(void)layoutSubviews{
    [super layoutSubviews];
    self.ownerCollectionView.frame=CGRectMake(0, 0, WIDTH, HEIGHT-353);
}


@end
